<tagLib name="html" />
<include file="Public:header" />
<script charset="utf-8" src="/Public/editor/kindeditor.js"></script>
<script charset="utf-8" src="/Public/editor/lang/zh_CN.js"></script>
<script>
        var editor;
        KindEditor.ready(function(K) {
			var options = {
				filterMode:false
			};
            editor = K.create('#editor_id',options);
        });
</script>

<script language="javascript" type="text/javascript" src="/Public/source/jquery.js"></script>
<script>
$(function(){
	$('#addNo').click(function(){
		$('#pic').val('');
		$('#video').val('');
		$('#showPic').css('display','none');
		$('#showVideo').css('display','none');
	});
	$('#addPic').click(function(){
		$('#video').val('');
		$('#showVideo').css('display','none');
		$('#showPic').css('display','block');
	});
	$('#addVideo').click(function(){
		$('#showPic').css('display','none');
		$('#pic').val('');
		$('#showVideo').css('display','block');
		$('#video').focus();
	});
})
</script>
<div style="width:100%; height:15px;color:#000;margin:0px 0px 10px;">
    <div style="float:left;"><a href="{YICMS::U('Index/stat')}" target="main"><b>控制面板首页</b></a>&nbsp;&raquo;&nbsp;添加内容</div>
</div>
<form action="{YICMS::U('Newslist/check')}" method="post" enctype="multipart/form-data">
    <table>
		<tr>
			<td>分类：</td>
			<td>
				<select name="pid" style="width:250px;padding:3px;margin-bottom:5px">
						<volist name="nav" id="vo">
							<option value="{YICMS:$vo['id']}">
									<php>
										for($i=1;$i<$vo['count'];$i++){
											echo '┣━&nbsp;';
										}
									</php>
								{YICMS:$vo['name']}
							</option>
						</volist>
				</select>
			</td>
		</tr>
		<tr>
			<td>标题：</td>
			<td><input type="text" id="title" name="title" style="height:25px;width:350px;margin-bottom:5px;"/></td>
		</tr>
		<tr>
			<td>内容：</td>
			<!-- <td><textarea id="editor_id" style="width:600px;height:180px;" name="content"></textarea></td> -->
			<td><textarea id="editor_id" name="content" style="width:100%;height:300px;"></textarea></td>
		</tr>
		<tr>
			<td>标签：</td>
			<td><input type="text" id="tag" name="tag" style="height:25px;width:200px;margin:5px 0;"/> 最多能添加3个.以空格分开!</td>
		</tr>
		<tr>
			<td>选择：</td>
			<td>
				<input type="button" id="addNo" value="不发布其他" style="padding:5px 20px;margin:10px;"/>
				<input type="button" id="addPic" value="发布图片" style="padding:5px 20px;margin:10px;"/>
				<input type="button" id="addVideo" value="发布视频" style="padding:5px 20px;margin:10px;"/>
			</td>
		</tr>
	</table>	
	<table id="showPic" style="display:none;">		
		<tr>
			<td>图片：</td>
			<td><input type="file" id="pic" name="pic" style="height:25px;width:200px;margin:5px 0;"/> 请注意图片大小,最大2MB..</td>
		</tr>
	</table>	
	<table id="showVideo" style="display:none;">
		<tr>
			<td>视频：</td>
			<td><input type="text" id="video" name="video" style="height:25px;width:200px;margin:5px 0;"/> 视频的flash地址..<a href="{YICMS::U('Index/index')}" target="_blank">点击查看<font color="red">上传视频演示例子</font></a></td>
		</tr>
	</table>
	<br/>
    <center><input type="submit" class="button" value="添 加"></center><br>
</form>
<br>
<include file="Public:footer" />